<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>[Generic Component Framework v3] GDriveLiteGui - Example application for GCF&#39;s GDriveLite</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
<!--link href="tabs.css" rel="stylesheet" type="text/css"-->
</head><body>
 <div id="wrapper">
    <div id="logo_box">
        <a class="img_link" href="https://github.com/pnudupa/gcf" target="_blank" ><img style="float:left;margin-left:10px;margin-top:5px;margin-bottom:5px;"src="header_gcf_logo.jpg" alt="GCF LOGO"/></a>
        <a class="img_link" href="https://www.vcreatelogic.com/" target="_blank" ><img style="float:right;margin-right:10px; margin-top: 30px;" src="header_vcl_logo.jpg" alt="VCL LOGO"/></a>
        <div style="clear:both"></div>
    </div>
    <div class="nav">
        <ul>
            <li class="selectedpage">
                <a class="a-home" href="index.html" >
                    <span>Home</span>
                </a>
            </li>
            <li>
                <a class="a-classes " href="classes.html">
                    <span>All Classes</span>
                </a>
            </li>
            <li>
                <a class="a-home " href="gcf_modules.html">
                    <span>Modules</span>
                </a>
            </li>
            <li>
                <a class="a-home " href="gcf_guides_and_videos.html">
                    <span>Guides & Videos</span>
                </a>
            </li>
            <li>
                <a class="a-home " href="gcf_tools_and_inbuilt_components.html">
                    <span>Tools & Components</span>
                </a>
            </li>
        </ul>
    </div>
    <div id="main-content">
        <div class="inside">
        <div>
<!-- Generated by Doxygen 1.8.16 -->
</div><!-- top -->
<div class="PageDoc"><div class="header">
  <div class="headertitle">
<div class="title">GDriveLiteGui - Example application for GCF's GDriveLite </div>  </div>
</div><!--header-->
<div class="contents">
<div class="toc"><h3>Table of Contents</h3>
<ul><li class="level1"><a href="#gcf_gdrivelitegui_0">Launching GDriveLiteGui</a></li>
<li class="level1"><a href="#gcf_gdrivelitegui_1">Uploading files</a></li>
<li class="level1"><a href="#gcf_gdrivelitegui_2">Downloading files</a></li>
<li class="level1"><a href="#gcf_gdrivelitegui_3">Sharing/Unsharing files and folders</a></li>
<li class="level1"><a href="#gcf_gdrivelitegui_4">Other options</a></li>
</ul>
</div>
<div class="textblock"><p>The GDriveLiteGui example showcases the capacity of <a class="el" href="group__gcf__gdrivelite.html">GCF's GDriveLite component</a> when used within a GUI (or widgets) application. The <a class="el" href="gcf_gdriveliteqml.html">GDriveLiteQml</a> example shows how the <a class="el" href="group__gcf__gdrivelite.html">GCF's GDriveLite component</a> component can be used in a QML application.</p>
<p>This page explains how to run the example and use the different kinds of functionality offered by it. It does not explain the source code and implementation of the example program.</p>
<p>We encourage you to take a look the source code of the example program and get a sense of how the <a class="el" href="group__gcf__gdrivelite.html">API</a> is used in it. This will help you with using <a class="el" href="group__gcf__gdrivelite.html">API</a> in your programs as well.</p>
<h1><a class="anchor" id="gcf_gdrivelitegui_0"></a>
Launching GDriveLiteGui</h1>
<p>To launch the program you will need to pass the <code>&ndash;clientID</code> and <code>&ndash;clientSecret</code> commandline parameters. The values passed to these parameters can be obtained from your <a class="el" href="group__gcf__gdrivelite.html#gcf_gdrivelite_0">Google API Console</a>.</p>
<p>Start terminal (or command-prompt) and launch the GDriveLiteGui example from the command-line as follows</p>
<p> 
<pre style="background: #000000">
<font color="white">$ ./GDriveLiteGui --clientID:78399023134.apps.googleusercontent.com --clientSecret:QiA5B6kXo0gNWcn-6UKpggsJ</font>
</pre>
</p>
<p>When the application is launched, you should see a login dialog as shown in the picture below.</p>
<div class="image">
<img src="gdrivelitegui1.png" alt=""/>
</div>
<p>In this dialog, you can enter your login credentials. [Note: You can enter login credentials of any Google Account, not just the account using which you registered the application in <a class="el" href="group__gcf__gdrivelite.html#gcf_gdrivelite_0">Google API Console</a>.] After login in, you will need to accept authorization for the GDriveLiteGui application. Once that is done, you will see a main-window as follows</p>
<div class="image">
<img src="gdrivelitegui2.png" alt=""/>
</div>
<p>On the left hand side you will notice a tree view. This view sources its data from <a class="el" href="class_g_c_f_1_1_i_g_drive_lite_content_model.html">GCF::IGDriveLiteContentModel</a>. The list/icon view on the top-half of the central area also sources its data from <a class="el" href="class_g_c_f_1_1_i_g_drive_lite_content_model.html">GCF::IGDriveLiteContentModel</a>. The bottom-half of the central area shows all attributes provided by Google Drive SDK against the selected item. Thumbnail of the selected item is shown towards the top-right. A user-pic of the selected file is shown right below it.</p>
<h1><a class="anchor" id="gcf_gdrivelitegui_1"></a>
Uploading files</h1>
<p>To upload a file, select any folder in "My Drive" and right click on it. From the list of options select Upload.</p>
<div class="image">
<img src="gdrivelitegui3.png" alt=""/>
</div>
<p>From the file-dialog box, shown next, select the file you want to upload. GDriveLiteGui will start uploading the file.</p>
<div class="image">
<img src="gdrivelitegui4.png" alt=""/>
</div>
<p>This workflow demonstrates the use of <a class="el" href="class_g_c_f_1_1_i_g_drive_lite_file_uploader.html">GCF::IGDriveLiteFileUploader</a> and GCF::IGDriveLiteFileUploaderList (or more specifically its base class <a class="el" href="class_g_c_f_1_1_job_list_model.html">GCF::JobListModel</a>)</p>
<h1><a class="anchor" id="gcf_gdrivelitegui_2"></a>
Downloading files</h1>
<p>To download a file, select any file in "My Drive" and right click on it. From the list of options select Download. Choose a directory on your computer where you want to download the file. GDriveLiteGui will download the file into that directory.</p>
<p>This workflow demonstrates the use of <a class="el" href="class_g_c_f_1_1_i_g_drive_lite_file_downloader.html">GCF::IGDriveLiteFileDownloader</a> and GCF::IGDriveLiteFileDownloaderList (or more specifically its base class <a class="el" href="class_g_c_f_1_1_job_list_model.html">GCF::JobListModel</a>)</p>
<h1><a class="anchor" id="gcf_gdrivelitegui_3"></a>
Sharing/Unsharing files and folders</h1>
<p>To share a file/folder; select an item in the tree-view on the left (within My Drive). Right click and select Share. This launches the sharing dialog box. This dialog-box shows all sharing permissions currently set on the file.</p>
<div class="image">
<img src="sharing-model-qml.png" alt=""/>
</div>
<p>Click on the "+" item (marked in blue) to add sharing permissions. This will launch another dialog box where you can enter the email-id of the person you want to share the file with. Once you click "Ok" on that dialog box, the share permissions gets added to the list.</p>
<p>To remove sharing permissions, simply click on the "x" button on any of the share permission items.</p>
<p>This workflow demonstrates the use of <a class="el" href="class_g_c_f_1_1_i_g_drive_lite_content_sharing_model.html">GCF::IGDriveLiteContentSharingModel</a></p>
<h1><a class="anchor" id="gcf_gdrivelitegui_4"></a>
Other options</h1>
<p>Context menu on an item in the tree view shows other options as well. The following list explains each of them.</p>
<ul>
<li>Rename - allows you to rename a file/folder [<a class="el" href="class_g_c_f_1_1_i_g_drive_lite.html#a0c7eadb4a9be38763f93ce849d1d730d">GCF::IGDriveLite::rename()</a>] </li>
<li>Describe - allows you to describe a file/folder [<a class="el" href="class_g_c_f_1_1_i_g_drive_lite.html#a4bf7fd14209172d7174159436842297c">GCF::IGDriveLite::describe()</a>] </li>
<li>Star/Unstar - allows you to flag a file/folder with a star or remove the star [<a class="el" href="class_g_c_f_1_1_i_g_drive_lite.html#a0d6884320dda4906735a6e8f9deeb810">GCF::IGDriveLite::star()</a>, <a class="el" href="class_g_c_f_1_1_i_g_drive_lite.html#a05e9e0a1606daf7501024ca0c7e4ed73">GCF::IGDriveLite::unstar()</a>] </li>
<li>Move - allows you to move a file/folder to another folder [<a class="el" href="class_g_c_f_1_1_i_g_drive_lite.html#a4995007b531a8974dd5c2d9851b13021">GCF::IGDriveLite::move()</a>] </li>
<li>Create directory - allows you to create a new directory [<a class="el" href="class_g_c_f_1_1_i_g_drive_lite.html#a5ed00b66bd6e537a04aa7449d890d1f6">GCF::IGDriveLite::mkdir()</a>] </li>
<li>Trash/Untrash/Delete permanently - allows you to support trash, untrash and delete fully workflows [<a class="el" href="class_g_c_f_1_1_i_g_drive_lite.html#a9ba8db39983072efb8ddfe54ecd78ec0">GCF::IGDriveLite::trash()</a>, <a class="el" href="class_g_c_f_1_1_i_g_drive_lite.html#ad3f211753cf7e7385127641645298a1c">GCF::IGDriveLite::restore()</a> and <a class="el" href="class_g_c_f_1_1_i_g_drive_lite.html#af648533fd1550593f70b68d15460cafc">GCF::IGDriveLite::deletePermanently()</a>] </li>
</ul>
</div></div><!-- contents -->
</div><!-- PageDoc -->
</div>
</div>
</div>
<div class="footer_content">
<table width="100%" class="footer">
<tr>
<td align="left" width="50%">Copyright &copy; 2013-2019,
 <a class="el" href="http://www.vcreatelogic.com" target="_black">VCreate Logic Private Limited</a></td>
<td align="right" width="50%"><a class="el" href="http://www.vcreatelogic.com/products/gcf" target="_black">GCF - Generic Component Framework</a></td>
</tr>
</table>
</div>
</div>
</body>
</html>
